import java.util.Stack;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: Administrator
 * Date: 2024-10-04
 * Time: 23:23
 */
public class Test {
    public static void main(String[] args) {
        Stack<Integer> stack = new Stack<>();
        stack.push(12);
        stack.push(23);
        stack.push(34);
        stack.push(45);
        stack.push(56);

        Integer x = stack.pop();
        System.out.println(x);
        Integer x1 = stack.pop();
        System.out.println(x1);

        System.out.println(stack.peek());
        System.out.println(stack.peek());
    }
}
